<include file="public@meta" />
<body>
<div class="layui-fluid">
    <div class="layui-card-body">
        <form method="post" action="{:url('admin/setting/password')}" class="layui-form">
            <div class="layui-form-item">
                <label class="layui-form-label">原密码</label>
                <div class="layui-input-block">
                    <input type="password" lay-verify="required" class="layui-input" name="old_password">
                </div>
            </div>
            <div class="layui-form-item">
                <label for="input-password" class="layui-form-label">新密码</label>
                <div class="layui-input-block">
                    <input type="password" lay-verify="required" class="layui-input" name="password">
                </div>
            </div>
            <div class="layui-form-item">
                <label for="input-repassword" class="layui-form-label">确认密码</label>
                <div class="layui-input-block">
                    <input type="password" lay-verify="required" class="layui-input" name="re_password">
                </div>
            </div>
            <div class="layui-form-item">
                <div class="layui-input-block">
                    <button type="submit" class="layui-btn layui-btn-primary" lay-submit lay-filter="general">
                        保存修改
                    </button>
                </div>
            </div>
        </form>
    </div>
</div>

<script>
    layui.config({
        base: '__STATIC__/layuiadmin/' //静态资源所在路径
    }).extend({
        index: 'lib/index', //主入口模块
        layCenter: 'lib/layCenter', //主入口模块
    }).use(['index', 'form','layCenter','common'], function(){
        var $ = layui.$,
            form = layui.form,
            layCenter = layui.layCenter,
            common = layui.common;
        //监听提交
        form.on('submit(layui-btn-form-submit)', function(data){
            console.log(data.field);
            layCenter.FormSubmit("{:url('edit')}",data.field,true);
        });

    });
</script>
</body>
</html>